//
//  LYFHomeTableViewController.swift
//  weibohhhh
//
//  Created by fersh on 16/1/2.
//  Copyright © 2016年 fersh. All rights reserved.
//

import UIKit
/**
 *  设置了navigationItem的左右item
 */
class LYFHomeTableViewController: LYFVistorTableViewController {
    
    override func viewDidLoad() {
        super.viewDidLoad()
        
        if userVistor == false {
            vistorView.setupVistorInfo(nil, messeageText: nil)
            return
        }
        setupUI()
    }
    /**
     为界面添加视图
     */
    private func setupUI(){
        
        navigationItem.leftBarButtonItem = UIBarButtonItem(imageName: "navigationbar_friendsearch",  target: self, action: "buttonItemClick")
        navigationItem.rightBarButtonItem = UIBarButtonItem(imageName: "navigationbar_pop" ,target: self, action: "buttonItemClick")
    }
    /**
     导航栏中的按钮点击方法
     */
    @objc private func buttonItemClick(){
        
        let vc = LYFViewController()
        navigationController?.pushViewController(vc, animated: true)
    }
    
    
    
}
